package march.firstmarch21.march03;

import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Mapper;

import java.io.IOException;

public class AcceptMapper extends Mapper<LongWritable, Text,Text,Text> {
    @Override
    protected void map(LongWritable key, Text value, Context context) throws IOException, InterruptedException {
        String line = value.toString();
        String[] split = line.split(",");
        //18620192711,15733218050,1506628174,1506628265,650000,810000
        String phone = split[1];
        String location = split[5];

        context.write(new Text(location),new Text(phone));
    }
}
